import React, { Component } from 'react';
import './Banner.scss'
import { Swiper } from 'antd-mobile'
class Banner extends Component<any,any> {
    render() {
        // console.log(this.props.swiperlist)
        return (
            <div className='banner'>
                <Swiper className='swiper' autoplay loop autoplayInterval={1500}>
                    {
                        this.props.swiperlist.map((item: any, index: number) => {
                            // console.log(item.img)
                            return (
                                <Swiper.Item key={index}>
                                    <img src={item.img===undefined?item:item.img} alt='' />
                                </Swiper.Item>
                            )
                        })
                    }
                </Swiper>
            </div>
        );
    }
}

export default Banner;